<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <script src="https://cdn.jsdelivr.net/npm/vue@2.6.10/dist/vue.js"></script>
    <title>Document</title>
</head>
<body>
    <div id="app">
     {{gradeAvg}}
    </div>
    <script>
        var app = new Vue({
            el:"#app",
            data:{
                students:[
                    {name:'lili',grade:88},
                    {name:"yaya",grade:90}
                ]
            },
            computed:{
                gradeAvg(){
                    return (this.students[0].grade+this.students[1].grade)/this.students.length
                }
            }
        })
    </script>
</body>
</html>